[% setvar title The Perl 6 Summary %]
<div id="archive-notice">
    <h3>This file is part of the Perl 6 Archive</h3>
    <p>To see what is currently happening visit <a href="http://www.perl6.org/">http://www.perl6.org/</a></p>
</div>
<div class='pod'>
<a name='The Perl 6 Summary'></a><h1>The Perl 6 Summary</h1>
<p>In case you were wondering, Darwin ports didn't work it's magic and I still
don't have a working Haskell compiler. Thank Juerd for feather, even if I did
have to turn my laptop upside down to read the MOTD. Rot-180: oN hes +snf</p>
<a name='This week in perl6-compiler'></a><h1>This week in perl6-compiler</h1>
<p>12 messages in the compiler list this week. Either everyone has decamped to IRC
or OSCON or the compiler's getting mature enough that most of the interesting
discussion about is happening in perl6-language as Autrijus and others seek
clarification.</p>
<a name='Some Thoughts on PIL/Complete Type Inferencing'></a><h2>Some Thoughts on PIL/Complete Type Inferencing</h2>
<p>Autrijus has been doing some thinking on the next version of PIL (The Pugs
Intermediate Language) which will be a little less tightly coupled with
PIR/Parrot. He outlined his thinking (which seems to be directed towards being
able to do useful things and optimizations with Type information) in this
thread.</p>
<p><a href='http://groups.google.com/groups?threadm=20050728205921.GA61292@aut.dyndns.org' target='_blank'>groups.google.com</a></p>
<a name='Definition of containers'></a><h2>Definition of containers</h2>
<p>Autrijus announced that he'd checked in the first part of the new PIL
run core. In case you were wondering, containers are the things that Perl
variables have as values. They're where things like 'tie' magic happens.</p>
<p><a href='http://groups.google.com/groups?threadm=20050730224910.GB5372@aut.dyndns.org' target='_blank'>groups.google.com</a></p>
<a name='Hoisting Variable declarations'></a><h2>Hoisting Variable declarations</h2>
<p>Hands up! How does the scoping of</p>
<pre>    {
       $x = $x + my $x if $x;
       #1   #2      #3    #4
    }</pre>
<p>work in Perl 6?</p>
<p>In Perl 5, all those <code>$x</code>s refer to the same thing. In Perl 6, #1 and #2 refer
to <code>$OUTER::x</code>.</p>
<p>This behaviour (lexical scopes really are lexical) makes a compiler writer's
head hurt. Autrijus outlined a plan for making it work.</p>
<p><a href='http://groups.google.com/groups?threadm=20050731180628.GC15882@aut.dyndns.org' target='_blank'>groups.google.com</a></p>
<a name='Meanwhile, in perl6-internals'></a><h2>Meanwhile, in perl6-internals</h2>
<a name='Dominance Frontier'></a><h2>Dominance Frontier</h2>
<p>Curtis Rawls had posted a patch adding 'dominance frontiers' to IMCC. (I'm
afraid I don't know what a dominance frontier is, but it sounds like it might
be fun.) This week he wondered if it could be applied any time soon, because he
had another patch that depended on it.</p>
<p>It turned out that the patch hadn't been applied because it broke a test or
two, and Will Coleda, Andy Dougherty, Patrick and Leo set about helping to
track it down. It looks like the issues have been found, and work continues to
fix them.</p>
<p><a href='http://groups.google.com/groups?threadm=rt-3.0.11-36597-118022.11.6916089811151@perl.org' target='_blank'>groups.google.com</a></p>
<a name=''make languages' should continue after building a language failed'></a><h2>'make languages' should continue after building a language failed</h2>
<p>Have you ever looked through the Parrot Makefiles and wondered what the deal is
with '.dummy'? If so, all is explained in this thread.</p>
<p><a href='http://groups.google.com/groups?threadm=rt-3.0.11-36647-118350.14.1074362091832@perl.org' target='_blank'>groups.google.com</a></p>
<a name='PMC syntax'></a><h2>PMC syntax</h2>
<p>Klaas-Jan Stol asked if there's any documentation about the complete syntax for
<b><i>.pmc</i></b> files when writing PMCs. Apparently there isn't, apart from the source
of <b><i>pmc2c.pl</i></b>, but Will Coleda and Leo helped Klaas-Jan out.</p>
<p><a href='http://groups.google.com/groups?threadm=42E7E7EC.1040907@home.nl' target='_blank'>groups.google.com</a></p>
<a name='Embedding ParTcl'></a><h2>Embedding ParTcl</h2>
<p>Thilo Planz had some problems embedding ParTcl into a PIR application. It
mostly worked, but he had a few questions. Will Coleda helped out again.</p>
<p><a href='http://groups.google.com/groups?threadm=42E838DC.9080804@web.de' target='_blank'>groups.google.com</a></p>
<a name='Compiling Dynamic PMCs'></a><h2>Compiling Dynamic PMCs</h2>
<p>Klaas-Jan had more questions about compiling PMCs. Dynamic ones this time. It
appears that the docs he was following didn't quite reflect reality. Leo solved
the problem and Klaas-Jan sent in a doc patch. Hurrah!</p>
<p><a href='http://groups.google.com/groups?threadm=42E8A3A2.5010100@home.nl' target='_blank'>groups.google.com</a></p>
<a name='Parrot cannot start up if STDERR or STDOUT is closed'></a><h2>Parrot cannot start up if STDERR or STDOUT is closed</h2>
<p>Michael Schwern pointed out that parrot won't start if you close either STDOUT
or STDERR. Eschewing the standard joke response (&quot;Doctor, it hurts when I do
this.&quot; &quot;Well don't do that then.&quot;) Jerry Gay wrote a test and Leo fixed it.</p>
<p><a href='http://groups.google.com/groups?threadm=rt-3.0.11-36677-118403.17.3306028943918@perl.org' target='_blank'>groups.google.com</a></p>
<a name='Accessing Hash with strings/keys'></a><h2>Accessing Hash with strings/keys</h2>
<p>Apparently Klaas-Jan is working on writing a lua compiler to target
Parrot. He's obviously working on it a good deal at the moment :)</p>
<p>He wanted to know how he could extend the standard Hash PMC to return 'None' if
no key is found. As is traditional in these cases, Leo helped him out. It turns
out that part of the problem is that pmc2c.pl isn't that strict in its syntax
checking. If anyone reading this has the tuits...</p>
<p><a href='http://groups.google.com/groups?threadm=42E9EAF7.1050509@home.nl' target='_blank'>groups.google.com</a></p>
<a name='Does it cost anything to use a big PMC everywhere'></a><h2>Does it cost anything to use a big PMC everywhere</h2>
<p>In a move guaranteed to gladden at least Dan Sugalski's heart, Amir Karger
popped up to say that he's working getting the Z-machine interpreter
working. He wondered if there was any way of dedicating a register to a
particular constant in order to avoid copying a global every time he called a
sub. Leo helped out.</p>
<p><a href='http://groups.google.com/groups?threadm=20050729165847.70341.qmail@web51110.mail.yahoo.com' target='_blank'>groups.google.com</a></p>
<a name='Super!'></a><h2>Super!</h2>
<p>Leo announced that he'd added a new Super PMC which will make it easier to call
superclass methods.</p>
<p><a href='http://groups.google.com/groups?threadm=42ECDE37.2010308@toetsch.at' target='_blank'>groups.google.com</a></p>
<a name='Lua Project'></a><h2>Lua Project</h2>
<p>Klaas-Jan unveiled his project to get the Lua compiler targetting Parrot. It's
apparently 'far from complete', but hey, it's good to welcome yet another
language to the parrot cage.</p>
<p><a href='http://members.home.nl/joeijoei/parrot' target='_blank'>members.home.nl</a></p>
<p><a href='http://groups.google.com/groups?threadm=42EF7E8F.9010304@home.nl' target='_blank'>groups.google.com</a></p>
<a name='Announcing mod_parrot 0.3'></a><h2>Announcing mod_parrot 0.3</h2>
<p>Jeff Horwitz announced the release of mod_parrot 0.3, complete with support for
all Apache hooks, autogeneration of request_rec methods and a mod_pugs proof of
concept. Crumbs. And there's more. Check out the announcement, download the
code and start making Apache do weird things. Go on, you know you want to.</p>
<p><a href='http://www.smashing.org/mod_parrot' target='_blank'>www.smashing.org</a></p>
<p><a href='http://groups.google.com/groups?threadm=Pine.LNX.4.44.0508021908110.3368-100000@booger.sixgeeks.org' target='_blank'>groups.google.com</a></p>
<a name='Meanwhile, in perl6-language'></a><h1>Meanwhile, in perl6-language</h1>
<a name='The Use and Abuse of Liskov'></a><h2>The Use and Abuse of Liskov</h2>
<p>Damian and Luke's discussion of the right way to do MMD looks to be finally
winding down. It seems Luke's convinced Damian of the righteousness of his
cause (or at least, if he's wrong, he's wrong in a subtler way than Damian
realised.) I don't think there's been a final decision as yet, but we're
definitely moving forward.</p>
<p><a href='http://groups.google.com/groups?threadm=42DB0A12.3060901@conway.org' target='_blank'>groups.google.com</a></p>
<a name='Slurpy parameters and auto flattening'></a><h2>Slurpy parameters and auto flattening</h2>
<p>Ingo Blechschmidt asked for some clarification of the behaviour of slurpy
parameters. It's not often I hope that Luke is wrong, but I really hope the
answer he gave Ingo isn't the true state of things.</p>
<p><a href='http://groups.google.com/groups?threadm=dc67qq$fjb$1@sea.gmane.org' target='_blank'>groups.google.com</a></p>
<a name='Exposing the Garbage Collector'></a><h2>Exposing the Garbage Collector</h2>
<p>Bah! I propose a simple, slow, yet powerful feature which can be used to
implement a whole bunch of other possible APIs for getting at stuff and people
go and suggest making any one of various heavier APIs the One True API. It's
enough to make a person despair.</p>
<p>Ah... apologies, I'm letting personal concerns get in the way of the summary,
but what the hell, I'm leaving it.</p>
<p><a href='http://groups.google.com/groups?threadm=42E7461D.5060801@orthogon.com' target='_blank'>groups.google.com</a></p>
<a name='Messing with the type hierarchy'></a><h2>Messing with the type hierarchy</h2>
<p>Luke had a few things to say about what happens when you monkey with the type
hierarchy. So he said them. The usual suspects joined in, most of them
addressing the particular instance that Luke had chosen to illustrate his
point, rather than discussing the broader point, but hey, this is
perl6-language, that's what happens.</p>
<p>Luke's broader question was &quot;Should it be possible to write a class that isn't
a leaf in the existing hierarchy?&quot; The example that everyone addressed was the
idea of writing a 'Complex' class that wedged in between 'Real' and 'Num' in
the hierarchy (which, as several people pointed out, isn't necessarily the
right way to think about it anyway, hence the discussion).</p>
<p>My gut feeling was that the answer to the general question should be &quot;Yes, but
be very, very careful and don't be surprise if it bites you later&quot;.</p>
<p><a href='http://groups.google.com/groups?threadm=7ca3f016050727040066a1464d@mail.gmail.com' target='_blank'>groups.google.com</a></p>
<a name='Elimination of Item|Pair and Any|Junction'></a><h2>Elimination of Item|Pair and Any|Junction</h2>
<p>The discussion of appropriate default prototypes the like continued. Autrijus
proposed a way of rejigging the type hierarchy to make default argument types a
little clearer. I found things getting a little weird to be honest -- there's
even talk of eliminating 'Object' as a type name, which seems a little strange.</p>
<p><a href='http://groups.google.com/groups?threadm=20050727120125.GA52424@aut.dyndns.org' target='_blank'>groups.google.com</a></p>
<a name='Execution platform object? Gestalt?'></a><h2>Execution platform object? Gestalt?</h2>
<p>Randal proposed that, as the number of possible platforms that Perl 6 can run
on proliferates, it'd be really handy if there was some useful global that held
knowledge about the platform and its capabilities. He proposed <code>$*OS</code> as a
decent place to put it. Larry thought we probably would have something like
that, but thought that there might end up being two globals, <code>$*OS</code> and
<code>$*VM</code>. The usual &quot;Why don't we call it...&quot; thread sprang up, but it seems
that the most important upshot is that this particular bike shed will definitely
be painted.</p>
<p><a href='http://groups.google.com/groups?threadm=86sly0jq6y.fsf@blue.stonehenge.com' target='_blank'>groups.google.com</a></p>
<a name='The meaning of returns'></a><h2>The meaning of <code>returns</code></h2>
<p>The continuing invasion by the rampaging hordes from p6c continued apace. This
time Autrijus had a discussion on the implications of <code>returns</code> and its
implications for type inferencing.</p>
<p><a href='http://groups.google.com/groups?threadm=20050727210305.GA30215@aut.dyndns.org' target='_blank'>groups.google.com</a></p>
<a name='Lazy list syntax'></a><h2>Lazy list syntax</h2>
<p>Flavio S. Glock wondered how to go about creating a lazy list from an
object. Apparently the magic he was missing was <code>prefix:=</code>, which is syntactic
sugar for calling the <code>.next</code> method on anything that supports
iteration. Which is nice.</p>
<p><a href='http://groups.google.com/groups?threadm=aa47605d050727161748eb9a9d@mail.gmail.com' target='_blank'>groups.google.com</a></p>
<a name='An idea for doing pack'></a><h2>An idea for doing pack</h2>
<p>David Formosa had an idea about a possible <code>pack</code> API, he outlined it on the
list. Yuval Kogman seemed to like it, but there's been nothing from anyone else
on the list.</p>
<p><a href='http://groups.google.com/groups?threadm=slrndeg0be.600.dformosa@dformosa.zeta.org.au' target='_blank'>groups.google.com</a></p>
<a name='Inferring (Foo of Int).does(Foo of Any)'></a><h2>Inferring (Foo of Int).does(Foo of Any)</h2>
<p>Autrijus again, this time thinking about the kind of type inferences that can
be done with Perl aggregate types. Once I'd got my head in the right space, it
made a great deal of sense, even if</p>
<pre>   (Array of Item).does(Array of Int); # false
   (Array of Int).does(Array of Item); # also false!</pre>
<p>made my head hurt the first time I read it.</p>
<p><a href='http://groups.google.com/groups?threadm=20050727231952.GB32639@aut.dyndns.org' target='_blank'>groups.google.com</a></p>
<a name='Garbage Collector API'></a><h2>Garbage Collector API</h2>
<p>Various additions to the proposed Garbage Collector API were proposed.</p>
<p><a href='http://groups.google.com/groups?threadm=slrndegbgc.600.dformosa@dformosa.zeta.org.au' target='_blank'>groups.google.com</a></p>
<a name='$value.confess()'></a><h2><code>$value.confess()</code></h2>
<p>Brent Royal-Gordon had a cunning idea for debugging of having Perl 6 capture
the call stack at their point of creation and stashing that in a property
called confess, which could be examined in a debugging context to find out
where a value came from. As he pointed out, this would be expensive, but
useful. He's currently Warnocked, but I get the feeling it should be possible
to write an extension to do what he wants without adding anything extra to Perl
6 itself. It might be a little tricky if he wants the call stack to change on
mutation though.</p>
<p><a href='http://groups.google.com/groups?threadm=b8b9a51105072813113f658a3f@mail.gmail.com' target='_blank'>groups.google.com</a></p>
<a name='Slurpy is rw arrays'></a><h2>Slurpy <code>is rw</code> arrays</h2>
<p>Having got clarification of the behaviour of normal slurpy arrays, Ingo
Blechschmidt asked for clarification of the behaviour of Slurp <code>is rw</code>
arrays. Adriano Ferreira and Thomas Sandlaß seemed to talk sense in reply.</p>
<p><a href='http://groups.google.com/groups?threadm=dccvvt$gei$1@sea.gmane.org' target='_blank'>groups.google.com</a></p>
<a name='Curious use of .assuming in S06'></a><h2>Curious use of <code>.assuming</code> in S06</h2>
<p>Autrijus wondered if code like:</p>
<pre>   &amp;textfrom := &amp;substr.assuming(:str($text) :len(Inf))</pre>
<p>found in Synopsis 6 was a mistake, or if the syntax was supposed to be like
that. It turns out that the syntax is supposed to be like that. Apparently
being able to do without the commas was one of the reasons for making colon
pair syntax look like that.</p>
<p><a href='http://groups.google.com/groups?threadm=20050729190650.GB83466@aut.dyndns.org' target='_blank'>groups.google.com</a></p>
<a name='Laziness and IO'></a><h2>Laziness and IO</h2>
<p>In a currently Warnocked post, David Formosa outlined a potential problem with
lazy IO.</p>
<p><a href='http://groups.google.com/groups?threadm=slrndekuuf.600.dformosa@dformosa.zeta.org.au' target='_blank'>groups.google.com</a></p>
<a name='sub foo ($x) returns ref($x)'></a><h2><code>sub foo ($x) returns ref($x)</code></h2>
<p>In his continuing discussion of the Perl 6 type system and the inferences that
can be drawn about it, Autrijus posted a discussion of how to declare that a
function that returns a value with the same type as its argument. He suggested
that the best way forward would be to declare something like:</p>
<pre>  sub identity ($x) returns ref($x) { ... }</pre>
<p>and asked for better suggestions. Thomas Sandlaß had suggestions.</p>
<p><a href='http://groups.google.com/groups?threadm=20050730082654.GA96554@aut.dyndns.org' target='_blank'>groups.google.com</a></p>
<a name='&amp;say's return value'></a><h2><code>&amp;say</code>'s return value</h2>
<p>Gaal Yahas thought that <code>&amp;print</code>, <code>&amp;say</code> should <code>fail</code> on errors and return
the printed string on success (but true). Larry thought not. So it looks like
they'll end up returning a Boolean or throwing an exception.</p>
<p><a href='http://groups.google.com/groups?threadm=20050730115601.GC1129@sike.forum2.org' target='_blank'>groups.google.com</a></p>
<a name='$arrayref.ref'></a><h2><code>$arrayref.ref</code></h2>
<p>Ingo continues his ongoing task of getting clarification of the semantics of a
whole host of things. This time he wanted to know about the behaviour of
references. Larry clarified.</p>
<p><a href='http://groups.google.com/groups?threadm=dcfr09$qhv$1@sea.gmane.org' target='_blank'>groups.google.com</a></p>
<a name='Binding scalars to aggregates'></a><h2>Binding scalars to aggregates</h2>
<p>Next up in Ingo's clarification project was binding scalars to aggregates (or
did he mean binding aggregates to scalars?). Again, Larry came through with
answers. It turns out that there's more to this than meets the eye at first
glance. Autrijus's post on Containers over in perl6-compiler addresses some of
these issues as well.</p>
<p><a href='http://groups.google.com/groups?threadm=dcfs2b$sk9$1@sea.gmane.org' target='_blank'>groups.google.com</a></p>
<a name='Binding hashes to arrays?'></a><h2>Binding hashes to arrays?</h2>
<p>Ingo asks &quot;Is it legal to bind a hash to an array or vice versa?&quot;</p>
<p>Larry answers &quot;Not at the moment.&quot;</p>
<p><a href='http://groups.google.com/groups?threadm=dcftim$vbt$1@sea.gmane.org' target='_blank'>groups.google.com</a></p>
<a name='Module init hooks and pragmas'></a><h2>Module init hooks and pragmas</h2>
<p>Gaal Yahas wondered what function in a module gets called when you 'use' or
'no' it.</p>
<p>Warnock applies.</p>
<p><a href='http://groups.google.com/groups?threadm=20050730173929.GE1129@sike.forum2.org' target='_blank'>groups.google.com</a></p>
<a name='Eliminating &amp;{} and *{}'></a><h2>Eliminating <code>&amp;{}</code> and <code>*{}</code></h2>
<p>Autrijus wondered if we really need the <code>&amp;</code> sigil. Warnock applies.</p>
<p><a href='http://groups.google.com/groups?threadm=20050731153353.GA15882@aut.dyndns.org' target='_blank'>groups.google.com</a></p>
<a name='Stringification of Pairs'></a><h2>Stringification of Pairs</h2>
<p>For some reason Ingo's shortest question (&quot;How do pairs stringify?&quot;) attracted
the largest response. Well, at first blush it looks like it did. What actually
happened was that it got Warnocked but the References: header in Andrew
Shitov's posed discussed below was a little broken...</p>
<p><a href='http://groups.google.com/groups?threadm=20050731153353.GA15882@aut.dyndns.org' target='_blank'>groups.google.com</a></p>
<a name='zip with ()'></a><h2><code>zip</code> with ()</h2>
<p>Andrew Shitov got caught out by some strange behaviour of <code>zip</code>. Ingo
explained what the problem was. There was quite a bit of discussion of the
various subtleties exposed.</p>
<p>Sometimes I pity the poor swine who's going to have to write Programming Perl
6. It's going to make the current camel look like a slim volume if we're not
careful.</p>
<p><a href='http://groups.google.com/groups?threadm=1846972468.20050731214453@shitov.ru' target='_blank'>groups.google.com</a></p>
<a name='Mutating map and grep'></a><h2>Mutating <code>map</code> and <code>grep</code></h2>
<p>Ingo Blechschmidt wondered if it was true that Perl 6's grep, map, etc,
wouldn't allow mutating values in their source array. He wondered if it would
be possible to use a pragma to get the old, Perl 5ish, behaviour back. Thomas
Sandlaß wondered if simply explicitly declaring the given block's argument as
<code>rw</code> wouldn't do the job. No word from @Larry yet.</p>
<p><a href='http://groups.google.com/groups?threadm=loom.20050801T120430-161@post.gmane.org' target='_blank'>groups.google.com</a></p>
<a name='Acknowledgements, adverts, apologies, alliteration and Conference envy'></a><h2>Acknowledgements, adverts, apologies, alliteration and Conference envy</h2>
<p>Damn... couldn't think of a word beginning with 'a' that means 'conference'. To
all you lucky people in Portland at OSCON, I wish I was there and am a seething
mass of envy. Well, not that seething: I'm consoling myself by going to the
WorldCon in Glasgow instead.</p>
<a name='Help Chip'></a><h2>Help Chip</h2>
<p><a href='http://geeksunite.org/,' target='_blank'>geeksunite.org</a> tell all your friends, this cannot stand.</p>
<a name='The usual Coda'></a><h2>The usual Coda</h2>
<p>If you find these summaries useful or enjoyable, please consider
contributing to the Perl Foundation to help support the development of
Perl.</p>
<p><a href='http://donate.perl-foundation.org/' target='_blank'>donate.perl-foundation.org</a> -- The Perl Foundation</p>
<p><a href='http://dev.perl.org/perl6/' target='_blank'>dev.perl.org</a> -- Perl 6 Development site</p>
<p>Check out my website, now running on a different blog engine and adorned with
even more new articles. And adverts and stuff. Buy books, click on Google
links, help me cover my bandwidth costs. You know you want to.</p>
<p><a href='http://www.bofh.org.uk/' target='_blank'>www.bofh.org.uk</a></p>
<p>Vaguely pretty photos by me can be found at:</p>
<p><a href='http://www.flickr.com/photos/pdcawley' target='_blank'>www.flickr.com</a></p>
</div>
